]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
A11yStatus: fix resetting the GTK and icon themes
authorGiovanni Campagna <gcampagna@src.gnome.org>
Fri, 18 Feb 2011 15:15:35 +0000 (16:15 +0100)
committerGiovanni Campagna <gcampagna@src.gnome.org>
Mon, 21 Feb 2011 17:50:35 +0000 (18:50 +0100)
If the Shell is started with HighContrast enabled, it will never
see another value for the GSettings keys. In that case, we just
reset to the default.

https://bugzilla.gnome.org/show_bug.cgi?id=642641

js/ui/status/accessibility.js

index b5b6cdbe1eeb76b5ee63d0c339e3c4508b6f324d..af503706fb0964b40fdcf7aa87d5d28d27334bbc 100644 (file)
@@ -168,9 +168,12 @@ ATIndicator.prototype = {
                 if (enabled) {
                     settings.set_string(KEY_GTK_THEME, HIGH_CONTRAST_THEME);
                     settings.set_string(KEY_ICON_THEME, HIGH_CONTRAST_THEME);
-                } else {
+                } else if(!hasHC) {
                     settings.set_string(KEY_GTK_THEME, gtkTheme);
                     settings.set_string(KEY_ICON_THEME, iconTheme);
+                } else {
+                    settings.reset(KEY_GTK_THEME);
+                    settings.reset(KEY_ICON_THEME);
                 }
             });
         settings.connect('changed::' + KEY_GTK_THEME, function() {